package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import javax.validation.constraints.NotNull;

import static org.jsola.hr.example.EmpModifyCompanyExample.E_EMP_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.E_NEW_COMPANY_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.E_OLD_COMPANY_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.E_USER_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_EMP_ID_MAX;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_NEW_COMPANY_ID_MAX;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_NEW_COMPANY_ID_NOT_NULL;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_OLD_COMPANY_ID_MAX;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_OLD_COMPANY_ID_NOT_NULL;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_USER_ID_MAX;
import static org.jsola.hr.example.EmpModifyCompanyExample.M_USER_ID_NOT_NULL;
import static org.jsola.hr.example.EmpModifyCompanyExample.N_EMP_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.N_NEW_COMPANY_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.N_OLD_COMPANY_ID;
import static org.jsola.hr.example.EmpModifyCompanyExample.N_USER_ID;

/**
 * 员工更换用工单位
 *
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【员工更换用工单位】的参数")
@Data
public class EmpModifyCompanyAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_EMP_ID, example = E_EMP_ID)
    @Length(max = 32, message = M_EMP_ID_MAX)
    private String empId;

    @ApiModelProperty(notes = N_USER_ID, example = E_USER_ID, required = true)
    @NotNull(message = M_USER_ID_NOT_NULL)
    @Length(max = 32, message = M_USER_ID_MAX)
    private String userId;

    @ApiModelProperty(notes = N_OLD_COMPANY_ID, example = E_OLD_COMPANY_ID, required = true)
    @NotNull(message = M_OLD_COMPANY_ID_NOT_NULL)
    @Length(max = 32, message = M_OLD_COMPANY_ID_MAX)
    private String oldCompanyId;

    @ApiModelProperty(notes = N_NEW_COMPANY_ID, example = E_NEW_COMPANY_ID, required = true)
    @NotNull(message = M_NEW_COMPANY_ID_NOT_NULL)
    @Length(max = 32, message = M_NEW_COMPANY_ID_MAX)
    private String newCompanyId;


}

